{% extends "generalTemplate.html" %}
{% block pageName %}BioVenturist - Latests posts{% endblock %}


{% block queryScript %}
<link type="text/css" rel="stylesheet" href="/bvblogapp/static/css/bvblogapp.css"></link>
{% endblock %}


{% block container %}
<div id="col2">
	<div class="pl2em">
    <table class="width100">
    	<tr>
    		<td style="padding: 0; margin: 0">
				<h1>List of users</h1>
			</td>
			<td style="padding: 0; margin: 0" align="right">
				&nbsp;
			</td>
		</tr>
	</table>
	{% load mod %}	
	<table class="user_list width100">
		<tr>
		{% for user in paginator.object_list %}
		  <td>
			<p class="user">
				<a href="{% url blog_index user.username %}">
				{% if user.first_name %}
					{{ user.first_name }}
				{% if user.last_name %}
					{{ user.last_name }}
				{% endif %}
				{% else %}
					{{ user.username }}
				{% endif %}
				</a><br />
				<small>(score: {% if user.score %}{{ user.score }}{% else %}0{% endif %})</small>
				
			</p>
		  </td>
		  {% if not forloop.counter|mod:4 %}
    	</tr>
		<tr>
		  {% endif %}
		{% endfor %}
		</tr>
	</table>

	<div id="pagination">
		{% if paginator.has_prev_page %}<a href="{% url users_with_analyses %}?page={{paginator.prev_page}}">&lt;</a>{% endif %}
		{% for page in paginator.page_range %}
			
			{% ifequal paginator.page page %} 
			<span class="strong">{{ page }}</span>&nbsp;
			{% else %}
			<a href="{% url users_with_analyses %}?page={{page}}">{{ page }}</a>&nbsp;
			{% endifequal %}
		{% endfor %}
		{% if paginator.has_next_page %}<a href="{% url users_with_analyses %}?page={{paginator.next_page}}">&gt;</a>{% endif %}		
	</div>
	</div>
</div>

{% endblock %}